-
Notifications
You must be signed in to change notification settings - Fork 12.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create (unstable) 2024 edition #94461
Conversation
Some changes occurred in src/tools/rustfmt. |
(rust-highfive has picked a reviewer for you, use r? to override) |
This comment has been minimized.
This comment has been minimized.
☔ The latest upstream changes (presumably #95552) made this pull request unmergeable. Please resolve the merge conflicts. |
Rebased. |
@@ -1033,7 +1033,7 @@ fn check_matcher_core( | |||
err.span_label(sp, format!("not allowed after `{}` fragments", kind)); | |||
|
|||
if kind == NonterminalKind::PatWithOr | |||
&& sess.edition == Edition::Edition2021 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch!
@bors r+ Based on discussion at https://zulip-archive.rust-lang.org/stream/213817-t-lang/topic/Deprecating.20macro.20scoping.20shenanigans.html#272860652 , there was support for this idea from @scottmcm , @joshtriplett , and @yaahc. I support it as well, and I think the people listed above represent enough of leadership to let this through in an unstable fashion. (The other approach would be to go through a formal T-compiler MCP to propose this as the official policy going forward. I'll at least mention this PR in the T-compiler meeting today, so people are aware that I unilaterally approved it.) |
📌 Commit 6b75406 has been approved by |
Create (unstable) 2024 edition [On Zulip](https://rust-lang.zulipchat.com/#narrow/stream/213817-t-lang/topic/Deprecating.20macro.20scoping.20shenanigans/near/272860652), there was a small aside regarding creating the 2024 edition now as opposed to later. There was a reasonable amount of support and no stated opposition. This change creates the 2024 edition in the compiler and creates a prelude for the 2024 edition. There is no current difference between the 2021 and 2024 editions. Cargo and other tools will need to be updated separately, as it's not in the same repository. This change permits the vast majority of work towards the next edition to proceed _now_ instead of waiting until 2024. For sanity purposes, I've merged the "hello" UI tests into a single file with multiple revisions. Otherwise we'd end up with a file per edition, despite them being essentially identical. `@rustbot` label +T-lang +S-waiting-on-review Not sure on the relevant team, to be honest.
Create (unstable) 2024 edition [On Zulip](https://rust-lang.zulipchat.com/#narrow/stream/213817-t-lang/topic/Deprecating.20macro.20scoping.20shenanigans/near/272860652), there was a small aside regarding creating the 2024 edition now as opposed to later. There was a reasonable amount of support and no stated opposition. This change creates the 2024 edition in the compiler and creates a prelude for the 2024 edition. There is no current difference between the 2021 and 2024 editions. Cargo and other tools will need to be updated separately, as it's not in the same repository. This change permits the vast majority of work towards the next edition to proceed _now_ instead of waiting until 2024. For sanity purposes, I've merged the "hello" UI tests into a single file with multiple revisions. Otherwise we'd end up with a file per edition, despite them being essentially identical. ``@rustbot`` label +T-lang +S-waiting-on-review Not sure on the relevant team, to be honest.
Create (unstable) 2024 edition [On Zulip](https://rust-lang.zulipchat.com/#narrow/stream/213817-t-lang/topic/Deprecating.20macro.20scoping.20shenanigans/near/272860652), there was a small aside regarding creating the 2024 edition now as opposed to later. There was a reasonable amount of support and no stated opposition. This change creates the 2024 edition in the compiler and creates a prelude for the 2024 edition. There is no current difference between the 2021 and 2024 editions. Cargo and other tools will need to be updated separately, as it's not in the same repository. This change permits the vast majority of work towards the next edition to proceed _now_ instead of waiting until 2024. For sanity purposes, I've merged the "hello" UI tests into a single file with multiple revisions. Otherwise we'd end up with a file per edition, despite them being essentially identical. ```@rustbot``` label +T-lang +S-waiting-on-review Not sure on the relevant team, to be honest.
Rollup of 11 pull requests Successful merges: - rust-lang#94457 (Stabilize `derive_default_enum`) - rust-lang#94461 (Create (unstable) 2024 edition) - rust-lang#94849 (Check var scope if it exist) - rust-lang#95194 (remove find_use_placement) - rust-lang#95749 (only downgrade selection Error -> Ambiguous if type error is in predicate) - rust-lang#96026 (couple of clippy::complexity fixes) - rust-lang#96027 (remove function parameters only used in recursion) - rust-lang#96034 ([test] Add test cases of untested functions for BTreeSet ) - rust-lang#96040 (Use u32 instead of i32 for futexes.) - rust-lang#96062 (docs: Update tests chapter for Termination stabilization) - rust-lang#96065 (Refactor: Use `format-args-capture` and remove unnecessary nested blocks in rustc_typeck) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Create (unstable) 2024 edition [On Zulip](https://rust-lang.zulipchat.com/#narrow/stream/213817-t-lang/topic/Deprecating.20macro.20scoping.20shenanigans/near/272860652), there was a small aside regarding creating the 2024 edition now as opposed to later. There was a reasonable amount of support and no stated opposition. This change creates the 2024 edition in the compiler and creates a prelude for the 2024 edition. There is no current difference between the 2021 and 2024 editions. Cargo and other tools will need to be updated separately, as it's not in the same repository. This change permits the vast majority of work towards the next edition to proceed _now_ instead of waiting until 2024. For sanity purposes, I've merged the "hello" UI tests into a single file with multiple revisions. Otherwise we'd end up with a file per edition, despite them being essentially identical. ````@rustbot```` label +T-lang +S-waiting-on-review Not sure on the relevant team, to be honest.
feat: Add `Edition2024` [RFC for `Edition2024`](rust-lang/rfcs#3501). While the RFC is not yet merged, this follows rustc which added the 2024 edition previously in rust-lang/rust#94461 This PR adds `Edition2024` as a possible value for `edition = "xxxx"`. I did this by following the [guide here](https://github.com/rust-lang/cargo/blob/ed0a7873107f48079a424da2920f7d434fd22fdc/src/cargo/core/features.rs#L163-L174).
On Zulip, there was a small aside regarding creating the 2024 edition now as opposed to later. There was a reasonable amount of support and no stated opposition.
This change creates the 2024 edition in the compiler and creates a prelude for the 2024 edition. There is no current difference between the 2021 and 2024 editions. Cargo and other tools will need to be updated separately, as it's not in the same repository. This change permits the vast majority of work towards the next edition to proceed now instead of waiting until 2024.
For sanity purposes, I've merged the "hello" UI tests into a single file with multiple revisions. Otherwise we'd end up with a file per edition, despite them being essentially identical.
@rustbot label +T-lang +S-waiting-on-review
Not sure on the relevant team, to be honest.